
package com.api;
 
 
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.scheduling.annotation.EnableAsync;
 
 
@SpringBootApplication
@EnableAutoConfiguration
@EnableAsync // 开启多任务
public class BaskApplication extends SpringBootServletInitializer {
    /**
     * main方法启动进入swagger-u
     * @param args
     */
    public static void main(String[] args) {
        SpringApplication.run(BaskApplication.class, args);
    }
    /**
     * Tomcat部署后启动（二者选其一，多余的进行注释）
     */
    @Override
    protected final SpringApplicationBuilder configure(final SpringApplicationBuilder application) {
        return application.sources(BaskApplication.class);
        
    }
    
 
    
}